package model;

import java.util.List;

/**
 * 菜单
 */
public class Menu {
    //标识列
    private Integer menuId;
    //菜单名称
    private String muneName;
    //上级菜单
    private Integer upmenuId;
    //状态
    private Integer state;
    //简介
    private String info;
    //菜单对应url
    private String url;
    //保证多表关系
    private List<Role> roles;
    //保存二级目录
    private List<Menu> secondMenus;

    public List<Menu> getSecondMenus() {
        return secondMenus;
    }

    public void setSecondMenus(List<Menu> secondMenus) {
        this.secondMenus = secondMenus;
    }

    @Override
    public String toString() {
        return "Menu{" +
                "menuId=" + menuId +
                ", muneName='" + muneName + '\'' +
                ", upmenuId=" + upmenuId +
                ", state=" + state +
                ", info='" + info + '\'' +
                ", url='" + url + '\'' +
                ", roles=" + roles +
                ", secondMenus=" + secondMenus +
                '}';
    }

    public Integer getMenuId() {
        return menuId;
    }

    public void setMenuId(Integer menuId) {
        this.menuId = menuId;
    }

    public String getMuneName() {
        return muneName;
    }

    public void setMuneName(String muneName) {
        this.muneName = muneName;
    }

    public Integer getUpmenuId() {
        return upmenuId;
    }

    public void setUpmenuId(Integer upmenuId) {
        this.upmenuId = upmenuId;
    }

    public Integer getState() {
        return state;
    }

    public void setState(Integer state) {
        this.state = state;
    }

    public String getInfo() {
        return info;
    }

    public void setInfo(String info) {
        this.info = info;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public List<Role> getRoles() {
        return roles;
    }

    public void setRoles(List<Role> roles) {
        this.roles = roles;
    }

    public Menu(Integer menuId, String muneName, Integer upmenuId, Integer state, String info, String url, List<Role> roles) {
        this.menuId = menuId;
        this.muneName = muneName;
        this.upmenuId = upmenuId;
        this.state = state;
        this.info = info;
        this.url = url;
        this.roles = roles;
    }

    public Menu() {
    }
}
